home *** CD-ROM | disk | FTP | other *** search
/ MacFormat 2000 July / macformat-092.iso / MacFormat 92 CD / Shareware Plus / Utilities / FolderSynchronizer 1.8.9 / PlugIn / Dialog / 00001_sGeneral.ls next >
Encoding:
Text File  |  2000-04-17  |  4.0 KB  |  185 lines

  1. on startMovie
  2.   global Nero, Bianco, gCHKSubFolder
  3.   set Nero to the foreColor of member "Nero"
  4.   set Bianco to the foreColor of member "Bianco"
  5. end
  6.  
  7. on AlertOK
  8.   global myMainWindow, gNextProcedura1
  9.   set myDialog to the pathName & "dialog"
  10.   close(window myDialog)
  11.   updateStage()
  12.   if voidp(myMainWindow) then
  13.     tell the stage
  14.       do(gNextProcedura1)
  15.     end tell
  16.   else
  17.     tell window myMainWindow
  18.       do(gNextProcedura1)
  19.     end tell
  20.   end if
  21. end
  22.  
  23. on moveWindow
  24.   global gRectWindDate, gRectWindTimerHour
  25.   case the frameLabel of
  26.     "PrefDate":
  27.       set gRectWindDate to the rect of the frontWindow
  28.     "TimerHour":
  29.       set gRectWindTimerHour to the rect of the frontWindow
  30.   end case
  31. end
  32.  
  33. on closeWindow
  34.   tell the stage
  35.     do("InitMenu")
  36.   end tell
  37. end
  38.  
  39. on SiNoOK
  40.   global Mittente, gNextProcedura1, gNextProcedura2, myMainWindow
  41.   if gNextProcedura1 = "myquit" then
  42.     tell the stage
  43.       beep()
  44.     end tell
  45.   else
  46.     set myDialog to the pathName & "dialog"
  47.     close(window myDialog)
  48.     updateStage()
  49.     if voidp(myMainWindow) then
  50.       tell the stage
  51.         do(gNextProcedura1)
  52.       end tell
  53.     else
  54.       tell window myMainWindow
  55.         do(gNextProcedura1)
  56.       end tell
  57.     end if
  58.   end if
  59. end
  60.  
  61. on SiNoCancel
  62.   global Mittente, gNextProcedura1, gNextProcedura2, myMainWindow
  63.   set myDialog to the pathName & "dialog"
  64.   close(window myDialog)
  65.   updateStage()
  66.   if voidp(myMainWindow) then
  67.     tell the stage
  68.       do(gNextProcedura2)
  69.     end tell
  70.   else
  71.     tell window myMainWindow
  72.       do(gNextProcedura2)
  73.     end tell
  74.   end if
  75. end
  76.  
  77. on VariabileOK
  78.   global Risposta
  79.   set myDialog to the pathName & "dialog"
  80.   set Risposta to the text of member "P1"
  81.   set ProssimoScript to the text of member "gNextProcedura1"
  82.   close(window myDialog)
  83.   tell the stage
  84.     set Risposta to Risposta
  85.   end tell
  86.   tell the stage
  87.     do(ProssimoScript & " Risposta")
  88.   end tell
  89. end
  90.  
  91. on Variabile3
  92.   global Risposta
  93.   set myDialog to the pathName & "dialog"
  94.   set Risposta to the text of member "P3"
  95.   set ProssimoScript to the text of member "gNextProcedura2"
  96.   close(window myDialog)
  97.   tell the stage
  98.     set Risposta to Risposta
  99.   end tell
  100.   tell the stage
  101.     do(ProssimoScript & " Risposta")
  102.   end tell
  103. end
  104.  
  105. on VariabileCancel
  106.   global Risposta
  107.   set myDialog to the pathName & "dialog"
  108.   set Risposta to the text of member "P2"
  109.   set ProssimoScript to the text of member "gNextProcedura3"
  110.   close(window myDialog)
  111.   tell the stage
  112.     set Risposta to Risposta
  113.   end tell
  114.   tell the stage
  115.     do(ProssimoScript & " Risposta")
  116.   end tell
  117. end
  118.  
  119. on SetDateOK
  120.   global gNextProcedura1, gDay, gMonth, gYear
  121.   if gNextProcedura1 = "myquit" then
  122.     tell the stage
  123.       beep()
  124.     end tell
  125.   else
  126.     set gDay to field "fGiorno"
  127.     set gMonth to field "fMese"
  128.     set gYear to field "fAnno"
  129.     if (gDay = EMPTY) or (gDay = 0) or (gMonth = EMPTY) or (gMonth = 0) or (gYear = EMPTY) or (gYear = 0) then
  130.       NoPassDate()
  131.     end if
  132.     if length(gYear) = 2 then
  133.       set gYear to Sinistra(OSConstDate(), 2) & gYear
  134.     end if
  135.     if value(gDay) > MaxGiorno() then
  136.       NoPassDate()
  137.     end if
  138.     set myDialog to the pathName & "dialog"
  139.     set ProssimoScript to gNextProcedura1
  140.     close(window myDialog)
  141.     updateStage()
  142.     tell the stage
  143.       do(ProssimoScript)
  144.     end tell
  145.   end if
  146. end
  147.  
  148. on NoPassDate
  149.   alert("No valid Date.")
  150.   abort()
  151. end
  152.  
  153. on SetTimerHourOK
  154.   global gNextProcedura1, gHour, gMinute
  155.   if gNextProcedura1 = "myquit" then
  156.     tell the stage
  157.       beep()
  158.     end tell
  159.   else
  160.     set gHour to field "fHour"
  161.     set gMinute to field "fMinute"
  162.     if (gHour = EMPTY) or (value(gHour) > 23) or (gMinute = EMPTY) or (value(gMinute) > 59) then
  163.       NoPassHour()
  164.     end if
  165.     if length(gHour) = 1 then
  166.       set gHour to "0" & gHour
  167.     end if
  168.     if length(gMinute) = 1 then
  169.       set gMinute to "0" & gMinute
  170.     end if
  171.     set myDialog to the pathName & "dialog"
  172.     set ProssimoScript to gNextProcedura1
  173.     close(window myDialog)
  174.     updateStage()
  175.     tell the stage
  176.       do(ProssimoScript)
  177.     end tell
  178.   end if
  179. end
  180.  
  181. on NoPassHour
  182.   alert("No valid Hour.")
  183.   abort()
  184. end
  185.